package com.example.demo.entity;

import java.sql.Timestamp;

public class Book {
    private int id;
    private int press_id;
    private String name;
    private String author;
    private Timestamp publish_time;
    private String sale_price;
    private String discount;
    private String category;
    private int stock;
    private int sales_total;
    private String user_no;
    private Timestamp opera_date;

    public Book() {
    }

    public Book(int id, int press_id, String name, String author, Timestamp publish_time, String sale_price, String discount, String category, int stock, int sales_total, String user_no, Timestamp opera_date) {
        this.id = id;
        this.press_id = press_id;
        this.name = name;
        this.author = author;
        this.publish_time = publish_time;
        this.sale_price = sale_price;
        this.discount = discount;
        this.category = category;
        this.stock = stock;
        this.sales_total = sales_total;
        this.user_no = user_no;
        this.opera_date = opera_date;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getPress_id() {
        return press_id;
    }

    public void setPress_id(int press_id) {
        this.press_id = press_id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public Timestamp getPublish_time() {
        return publish_time;
    }

    public void setPublish_time(Timestamp publish_time) {
        this.publish_time = publish_time;
    }

    public String getSale_price() {
        return sale_price;
    }

    public void setSale_price(String sale_price) {
        this.sale_price = sale_price;
    }

    public String getDiscount() {
        return discount;
    }

    public void setDiscount(String discount) {
        this.discount = discount;
    }

    public String getCategory() {
        return category;
    }

    public void setCategory(String category) {
        this.category = category;
    }

    public int getStock() {
        return stock;
    }

    public void setStock(int stock) {
        this.stock = stock;
    }

    public int getSales_total() {
        return sales_total;
    }

    public void setSales_total(int sales_total) {
        this.sales_total = sales_total;
    }

    public String getUser_no() {
        return user_no;
    }

    public void setUser_no(String user_no) {
        this.user_no = user_no;
    }

    public Timestamp getOpera_date() {
        return opera_date;
    }

    public void setOpera_date(Timestamp opera_date) {
        this.opera_date = opera_date;
    }

    @Override
    public String toString() {
        return "Book{" +
                "id=" + id +
                ", press_id=" + press_id +
                ", name='" + name + '\'' +
                ", author='" + author + '\'' +
                ", publish_time=" + publish_time +
                ", sale_price='" + sale_price + '\'' +
                ", discount='" + discount + '\'' +
                ", category='" + category + '\'' +
                ", stock=" + stock +
                ", sales_total=" + sales_total +
                ", user_no='" + user_no + '\'' +
                ", opera_date=" + opera_date +
                '}';
    }
}
